var allwrites = {};
var urls = {};
var uname = mjt.urlquery.user;
var timeconst = "2006";
if (pastdays) {
var NowObj = new Date();
timecObj = new Date(0);
timecObj.setUTCFullYear(NowObj.getUTCFullYear(), NowObj.getUTCMonth(), NowObj.getUTCDate()- pastdays);
var mMonth = timecObj.getUTCMonth(); mMonth++ ; if (mMonth < 10) { mMonth = "0" + mMonth + "";}
var mDate = timecObj.getUTCDate(); if (mDate < 10) { mDate = "0" + mDate + "";}
timeconst = timecObj.getUTCFullYear() + "-" + mMonth + "-" + mDate;
}
mjt.mqlread([{
"/type/reflect/any_value":[{
"link":{
"creator":uname,
"master_property":{
"id":null,
"name":null
},
"operation":null,
"timestamp>":timeconst,
"timestamp":null
},
"sort":"-link.timestamp",
"value":null
}],
"id":null,
"limit":200,
"name":null,
"sort":["-/type/reflect/any_value.link.timestamp"]
}])
var url = write.id + "";
url = url.replace(/#/,"%23");
url = "http://www.freebase.com/view?id=" + url;
var topicName = write.name;
if (!(topicName)) {topicName = write.id;}
if (!allwrites[topicName]) {
allwrites[topicName] = new Array();
urls[topicName] = url;
}
var propVal = action.name;
if (!(propVal)) {propVal = action.value;}
if (!(propVal)) {propVal = action.id;}
var thisWrite = new Array(
action.link.timestamp, action.link.operation, action.link.master_property.name, propVal
);
allwrites[topicName].push(thisWrite);
${getMWrites(allwrites, urls, pastdays)}
pastdays = 31
Error. Trying just the past $pastdays days
${getVWrites(pastdays)}
pastdays = pastdays - 15
Error. Trying just the past $pastdays days
${getVWrites(pastdays)}
Unrecoverable Error
${mjt.log('Error in', getwrites)}
var allwrites = {};
var urls = {};
var uname = mjt.urlquery.user;
var yearmonthday = day.split("-");
var dateObj = new Date(0);
dateObj.setUTCFullYear(yearmonthday[0], (yearmonthday[1]) -1, yearmonthday[2]);
dateObj.setTime(dateObj.valueOf() + (12*3600*1000));
var aMonth = dateObj.getUTCMonth() +1; if (aMonth < 10) { aMonth = "0" + aMonth + "";}
var aDate = dateObj.getUTCDate(); if (aDate < 10) { aDate = "0" + aDate + "";}
var timestart = dateObj.getUTCFullYear() + "-" + aMonth + "-" + aDate + "T11:00";
dateObj.setTime(dateObj.valueOf() + (24*3600*1000));
aMonth = dateObj.getUTCMonth()+1; if (aMonth < 10) { aMonth = "0" + aMonth + "";}
aDate = dateObj.getUTCDate(); if (aDate < 10) { aDate = "0" + aDate + "";}
var timeend = dateObj.getUTCFullYear() + "-" + aMonth + "-" + aDate + "T13:00";
mjt.mqlread([{
"/type/reflect/any_value":[{
"link":{
"creator":uname,
"master_property":{
"id":null,
"name":null
},
"operation":null,
"timestamp>":timestart,
"timestamp<":timeend,
"timestamp":null
},
"value":null
}],
"id":null,
"limit":200,
"name":null,
}])
var url = write.id + "";
url = url.replace(/#/,"%23");
url = "http://www.freebase.com/view?id=" + url;
var topicName = write.name;
if (!(topicName)) {topicName = write.id;}
if (!allwrites[topicName]) {
allwrites[topicName] = new Array();
urls[topicName] = url;
}
var propVal = action.name;
if (!(propVal)) {propVal = action.value;}
if (!(propVal)) {propVal = action.id;}
var thisWrite = new Array(
action.link.timestamp, action.link.operation, action.link.master_property.name, propVal
);
allwrites[topicName].push(thisWrite);
${getMWritesDay(allwrites, urls, day, timestart, timeend)}
Error!
${mjt.log('Error in', getwrites)}
if (!(allwrites)) {var allwrites = {};}
if (!(urls)) {var urls = {};}
var uname = mjt.urlquery.user;
mjt.mqlread([{
"/type/reflect/any_master": [{
"link":{
"creator":uname,
"master_property":{
"id":null,
"name":null
},
"operation":null,
"timestamp>":timestart,
"timestamp<":timeend,
"timestamp":null
},
"id":null,
"name":null,
}],
"name":null,
"id":null,
"limit":200
}])
var url = write.id + "";
url = url.replace(/#/,"%23");
url = "http://www.freebase.com/view?id=" + url;
var topicName = write.name;
if (!(topicName)) {topicName = write.id;}
if (!allwrites[topicName]) {
allwrites[topicName] = new Array();
urls[topicName] = url;
}
var propLink = action.id + "";
propLink = propLink.replace(/#/,'%23');
propLink = "http://www.freebase.com/view?id=" + propLink;
var propVal = action.name;
if (!(propVal)) {propVal = action.value;}
if (!(propVal)) {propVal = action.id;}
var thisWrite = new Array(
action.link.timestamp, action.link.operation, action.link.master_property.name, propVal, propLink
);
allwrites[topicName].push(thisWrite);
function sortWritesByTimestamp(a,b)
{
b[0] > a[0] ? x=1 : x=-1 ;
return x;
}
allwrites[topicName].sort(sortWritesByTimestamp);
var names = [];
for (name in urls) {
names.push(name);
}
function latestWriteSort(a,b) {
allwrites[b][0][0] > allwrites[a][0][0] ? x=1 : x=-1;
return x;
}
names.sort(latestWriteSort);
${displayresult(allwrites, urls, names)}
Error!
${mjt.log('Error in', getwrites)}
if (!(allwrites)) {var allwrites = {};}
if (!(urls)) {var urls = {};}
var uname = mjt.urlquery.user;
var timeconst = "2006";
if (pastdays) {
var NowObj = new Date();
timecObj = new Date(0);
timecObj.setUTCFullYear(NowObj.getUTCFullYear(), NowObj.getUTCMonth(), NowObj.getUTCDate()- pastdays);
var mMonth = timecObj.getUTCMonth(); mMonth++ ; if (mMonth < 10) { mMonth = "0" + mMonth + "";}
var mDate = timecObj.getUTCDate(); if (mDate < 10) { mDate = "0" + mDate + "";}
timeconst = timecObj.getUTCFullYear() + "-" + mMonth + "-" + mDate;
}
mjt.mqlread([{
"/type/reflect/any_master": [{
"link":{
"creator":uname,
"master_property":{
"id":null,
"name":null
},
"operation":null,
"timestamp>":timeconst,
"timestamp":null,
},
"id":null,
"name":null,
"sort":"-link.timestamp"
}],
"name":null,
"id":null,
"limit":200,
"sort":["-/type/reflect/any_master.link.timestamp"]
}])
var url = write.id + "";
url = url.replace(/#/,"%23");
url = "http://www.freebase.com/view?id=" + url;
var topicName = write.name;
if (!(topicName)) {topicName = write.id;}
if (!allwrites[topicName]) {
allwrites[topicName] = new Array();
urls[topicName] = url;
}
var propLink = action.id + "";
propLink = propLink.replace(/#/,'%23');
propLink = "http://www.freebase.com/view?id=" + propLink;
var propVal = action.name;
if (!(propVal)) {propVal = action.value;}
if (!(propVal)) {propVal = action.id;}
var thisWrite = new Array(
action.link.timestamp, action.link.operation, action.link.master_property.name, propVal, propLink
);
allwrites[topicName].push(thisWrite);
function sortWritesByTimestamp(a,b)
{
b[0] > a[0] ? x=1 : x=-1 ;
return x;
}
allwrites[topicName].sort(sortWritesByTimestamp);
var names = [];
for (name in urls) {
names.push(name);
}
function latestWriteSort(a,b) {
allwrites[b][0][0] > allwrites[a][0][0] ? x=1 : x=-1;
return x;
}
names.sort(latestWriteSort);
${displayresult(allwrites, urls, names)}
pastdays = 31
Error. Trying just the past $pastdays days
${getMWrites(allwrites, urls, pastdays)}
pastdays = pastdays - 15
Error. Trying just the past $pastdays days
${getMWrites(allwrites, urls, pastdays)}
Unrecoverable Error
${mjt.log('Error in', getwrites)}
No values or masters found
| Topic |
Action |
Property |
Value |
Date |
| $topic |
${write[1]} |
${write[2]} |
|
${write[3]} |
${formatTime(write[0])} |
var datetime = timestamp.split("T");
var ymd = datetime[0].split("-");
var months = ['NaN', 'Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'];
datetime[1] = datetime[1].slice(0,8)
${months[ymd[1] *1]} ${ymd[2]}, ${ymd[0]} ${datetime[1]} Z
${showUsersList()}
${getVDayWrites(mjt.urlquery.day)}
${showUsersList()}
${getVWrites(false)}
Recent edits by user
${showUsersList()}
Please enter a user